package com.lc.fbtp.draftmsg.api.paper;

import java.io.Serializable;

import com.thoughtworks.xstream.annotations.XStreamAlias;

@XStreamAlias("MainBody")
public class MainBody implements Serializable{

	/**
	 * 序列号
	 */
	private static final long serialVersionUID = 2604365612763939745L;

	/**
	 * 报文标识
	 */
	@XStreamAlias("MsgId")
	private MsgId MsgId;
	
	/**
	 * 原报文标识
	 */
	@XStreamAlias("OrgnlMsgId")
	private OrgnlMsgId OrgnlMsgId;
	/**
	 * 获取id
	 * @return
	 */
	public String getId(){
		return MsgId.getId();
	}
	
	/**
	 * 获取报文时间 
	 * @return
	 */
	public String getDtTm(){
		return MsgId.getCreDtTm();
	}
	
	/**
	 * 获取原报文号
	 * @return
	 */
	public String getOrgnlId(){
		if(OrgnlMsgId != null){
			return OrgnlMsgId.getCreDtTm();
		}
		return null;
	}
	
	public String getOrgnlCreDtTm(){
		if(OrgnlMsgId != null){
			return OrgnlMsgId.getCreDtTm();
		}
		return null;
	}

	public MsgId getMsgId() {
		return MsgId;
	}

	public void setMsgId(MsgId msgId) {
		MsgId = msgId;
	}

	public OrgnlMsgId getOrgnlMsgId() {
		return OrgnlMsgId;
	}

	public void setOrgnlMsgId(OrgnlMsgId orgnlMsgId) {
		OrgnlMsgId = orgnlMsgId;
	}
	
}
